# if 5 > 2:
#     print('5 > 2')
#
#
# def plus2(x):
#     return x + 2
#
#
# print('xxx')
#
# s = 'aasssss\nasasasas\naaaa'
#
# print(s)
#
# s2 = """
# aasssss
# asasasas
# aaaa
# """
#
# print(s2)
#
# s3 = 'book'
# f'This is a {s3}'
# b'Hello'
# a = 0
# print(len(str(3**1000)))

# is
# in
# print(isinstance(a, int))
# =
# ==
# None
# 实例

# a = {}
#
# if a:
#     print('a')
# else:
#     print('b')
#
# if a is None:
#     print('c')
# else:
#     print('d')
#
#
# def my_len(li=None):
#     if li is None:
#         li = []
#     return len(li)
#
# print(my_len([1,2,3]))
#
# b = None
#
# if b is None:
#     print('e')
#
# print(id(b))
# print(id(None))
#
# c = [3]
# d = [3]
# print(c is d)
# print(c == d)
#
# print(id(3))
#
# print(a)
# if a is not None:
#     print('a')
# else:
#     print('b')
#
# if not (a is None):
#     print('b')
# else:
#     print('a')
#
# a = 4
# if a > 2 and b is None:
#     print('xxx')
#
# a = 1 if a > 0 else 0 if a == 0 else -1
#
# a = []
# a += [3]
# print(a)
#
#
# def myfunction():
#     pass

# a = [1, 2, 3, 4, 5]
# for x in a:
#     if x % 2 == 1:
#         continue
#     print(x)
#
#
# def max_list(li):
#     if len(li) == 0:
#         raise('List is []')
#     my_max = li[0]
#     for l in li[1:]:
#         if l > my_max:
#             my_max = l
#     return my_max
#
# print(max_list([2,3,2,43,35,46,45,-2,4335,346]))
# print(max_list([]))

def my_iter(n):
    for j in range(n):
        yield j

x = my_iter(7)
print(type(x))

for i in x:
    print(i)
